{literal}
<script type="text/javascript">
    function checkLength()
    {
        if(document.getElementById('maintext').value.length > 20000)
        {
            alert('{/literal}{language text="error_long_text"}{literal}');
            return false;
        }
        else
            return true;
    }
</script>
{/literal}
<table style="width: 100%;" cellpadding="4" cellspacing="0">
	<tr>
		<td class="border2">
		
			<table style="width: 100%;" class="mainmenu5" cellpadding="0" cellspacing="0" border="0">
				<tr>
					<td width="7"><img src="design/pic/spacer.gif" class="sqr1" alt="" height="7" width="7" /></td>
					<td class="block_header">{$sBoxName}</td>
				</tr>
			</table>
			
{if $bPreview}
<table style="width: 100%;" cellpadding="4" cellspacing="4">
	<tr>
		<td class="border2">
		
			<table style="width: 100%;" class="mainmenu5" cellpadding="0" cellspacing="0" border="0">
				<tr>
					<td width="7"><img src="design/pic/spacer.gif" class="sqr1" alt="" height="7" width="7" /></td>
					<td class="block_header">{language text="preview"}</td>
				</tr>
			</table>
    		{$sPreviewTxt}
		</td>
	</tr>
</table>
{/if}
<div style="padding-left: 20px; padding-top: 2px;">
{$jsValMess}
{messages template='_blocks/errors_block.html' title='COMPOSE ERRORS'}
    <form method="post"	action="{$sUrl}" onsubmit="if(!checkLength())return false; else {$jsValidation}">
    <table style="width:100%;" cellspacing="2" cellpadding="4">
    <tr>
        <td style="text-align:right;" class="color"><span class="star">*</span> {language text="subject"}:</td>
        <td class="border13">
            <input value="{$aMess.title}" maxlength="60" id="user" name="aMess[title]" size="40" onfocus="this.className='inputmain';" onblur="this.className='';" type="text">
        </td>
    </tr>
    <tr>
        <td colspan="2">
            <span style="vertical-align: top; padding: 5px;"><span class="star">*</span> {language text="content"}</span>
            <div style="padding: 5px;">
                <textarea style="width:100%" cols="55" rows="15" id="maintext" name="aMess[text]" onfocus="this.className='textarea';" onblur="this.className='';">{$aMess.text}</textarea>
            </div>
            {include file="$sMainTemplatePath/_blocks/smilies.html"}
        </td>
    </tr>
    <tr>
        <td colspan="2"><span class="star">*</span> - {language text="mandatory_fields"}</td>
    </tr>
    <tr>
        <td></td>
        <td>
            <input style="cursor: pointer;" name="act[sSend]" value=" {language text="submit_bulletin"} " type="submit"  class="mainmenu6" onmouseover="this.className='mainmenu7';" onmouseout="this.className='mainmenu6';" />
            <input style="cursor: pointer;" name="act[sPrev]" value="{language text="preview_456"}" type="submit"  class="mainmenu6" onmouseover="this.className='mainmenu7';" onmouseout="this.className='mainmenu6';" />
            <span style="padding-left: 20px; font-size: 7pt;"> 
                <a class="link_action" href="javascript:void(0);" onclick="popUp2('{url link=public.popup.help}','500','500','yes','200','100');">[ {language text="html_guide"} ]</a>
            </span>        
        </td>
    </tr>
    </table>
    </form>
</div>    

		</td>
	</tr>
</table>